Marquee #6: The Stop Button
This script repeats the functionality of Marquee #2, with an
added "stop" button.
Discussion
Halt timeout-loops by calling clearTimeout
on the current timeout process. In this example of the onClick
event handler,
onClick="clearTimeout(JSCTimeOutID)"
clears the pending event and prevents the
setMessage() event from executing and
hence, from starting a new timeout.
Copyright ©2000 by Charles River Media, All Rights Reserved